//
//  CWRefreshControl.swift
//  CWWeibo06
//
//  Created by ycw on 2017/7/30.
//  Copyright © 2017年 xiaowei. All rights reserved.
//

import UIKit

/**
 自定义下拉刷新控件
 */
private let CWRefreshControlHeight: CGFloat = 50

class CWRefreshControl: UIControl {

    override init(frame: CGRect) {
        super.init(frame: frame)
        setupUI()
    }
    
    required init?(coder aDecoder: NSCoder) {
        fatalError("init(coder:) has not been implemented")
    }
    
    fileprivate func setupUI() {
        self.backgroundColor = UIColor.red
        self.frame.size.width = UIScreen.main.bounds.size.width
        self.frame.size.height = CWRefreshControlHeight
        self.frame.origin.y = -CWRefreshControlHeight
    }

}
